/*
 * Filename OldModel.java 2021年10月29日
 * Copyright © Ehome Co.Ltd. All Rgiths Reserved.
 * @author wuyingchao
 */
package com.ehome.poct.core.dao.entity;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableLogic;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import com.ehome.mybatisplus.autoconfigure.DO;
import lombok.Data;

import java.time.LocalDateTime;

/**
 * 旧的基础模型
 *
 * @author wyc
 * @since 2021/10/29 10:54
 **/
@Data
public class NewModel<T extends Model<?>> extends DO<T> {
    @TableField(value = "create_by", fill = FieldFill.INSERT)
    public Long createBy;
    @TableField(value = "create_time", fill = FieldFill.INSERT)
    public LocalDateTime createTime;
    @TableField(value = "update_by", fill = FieldFill.INSERT_UPDATE)
    public Long updateBy;
    @TableField(value = "update_time", fill = FieldFill.INSERT_UPDATE)
    public LocalDateTime updateTime;
    @TableLogic(value = "NULL", delval = "NOW()")
    @TableField("delete_time")
    public LocalDateTime deleteTime;
    @TableField(value = "trace_id", fill = FieldFill.INSERT_UPDATE)
    public String traceId;
}